<?xml version="1.0" encoding="utf-8" ?>
<taskrunner name="update.localdb" version="1.0" date="2008-10-01" maxthreads="1">

  <!-- log
    2009-11-05/MMA  Removed condition -condition="¤{KeepLocalDb}=true"- from tasks 
  
  
  -->

  <includes>
    <file name="vida.install.settings.xml" />
  </includes>
  
  <resources>
    <resource name="SqlScript" maxusers="1"/>
  </resources>

 
 

  <tasks>

    

    <foreach enum="MasterUpdates" orderby="sequence">
      <task name="update.master"  allowMultipleInstances="true" typename="@SqlServerManagement.ExecuteScript">
        <description>
          If accessserver is not replaced earlier then we run this sql script in order to update it to current version.
        </description>
        <resources list="SqlScript"/>
        <dependencies list=""/>
        <parameters>
          <parameter name="connectionstring" value="${master.cs}"/>
          <parameter name="script.fullpath" value="${target.db.update.dir}\$[MasterUpdates:key]"/>
        </parameters>
      </task>
    </foreach>

    <foreach enum="AccessServerUpdates" orderby="sequence" >
      <task name="update.accessserver"  allowMultipleInstances="true" typename="@SqlServerManagement.ExecuteScript">
        <description>
          If accessserver is not replaced earlier then we run this sql script in order to update it to current version.
        </description>
        <resources list="SqlScript"/>
        <dependencies list=""/>
        <parameters>
          <parameter name="connectionstring" value="${accessserver.cs}"/>
          <parameter name="script.fullpath" value="${target.db.update.dir}\$[AccessServerUpdates:key]"/>
        </parameters>
      </task>
    </foreach>

    <foreach enum="BaseDataUpdates">
      <task name="update.basedata"  allowMultipleInstances="true" typename="@SqlServerManagement.ExecuteScript">
        <description>
          Updates basedata
        </description>
        <resources list="SqlScript"/>
        <dependencies list=""/>
        <parameters>
          <parameter name="connectionstring" value="${basedata.cs}"/>
          <parameter name="script.fullpath" value="${target.db.update.dir}\$[BaseDataUpdates:key]"/>
        </parameters>
      </task>
    </foreach>

    <foreach enum="DiagSwdlSessionUpdates">

      <task name="update.diagswdlsession"  allowMultipleInstances="true" typename="@SqlServerManagement.ExecuteScript">
        <description>
          Updates database DiagSwdlSession
        </description>
        <resources list="SqlScript"/>
        <dependencies list=""/>
        <parameters>
          <parameter name="connectionstring" value="${diagswdlsession.cs}"/>
          <parameter name="script.fullpath" value="${target.db.update.dir}\$[DiagSwdlSessionUpdates:key]"/>
        </parameters>
      </task>
    </foreach>


  </tasks>
</taskrunner>